package com.yd.mvc.mobile.agreementController;

import com.yd.app.service.mobile.agreementService.MAgreementService;
import com.yd.domain.business.Agreement;
import com.yd.mvc.baseController.BaseController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * 优惠券
 * Created by sunxianhui on 2018/3/9.
 */
@RestController
@RequestMapping(value = "/dapi/magreement")
public class MAgreementController extends BaseController {
    @Autowired
    MAgreementService agreementService;

    /**
     * @Author: zy
     * @Desc: 手机端查看协议说明根据类型查看
     * @Date:  2018/3/15
     * @Param
     */
    @RequestMapping(value = "/getXy/{xyType}", method = RequestMethod.GET)
    public Agreement getAgreementList(@PathVariable("xyType")String xyType) {
        Agreement agreement =new Agreement();
        agreement=agreementService.getXyByType(xyType);
        return  agreement;
    }
}
